package com.house.framework.vo;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.house.framework.entity.BaseEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.util.Date;

/**
 * @ClassName User
 * @Version 1.0
 */
@Data
@TableName("t_user")
@ApiModel(value = "user对象", description = "用户")
public class UserVo extends BaseEntity {

    @ApiModelProperty("用户表主键")
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    @ApiModelProperty("姓名")
    @TableField("name")
    private String name;

    @ApiModelProperty("用户名")
    @TableField("username")
    private String username;

    @ApiModelProperty("邮箱")
    @TableField("email")
    private String email;

    @ApiModelProperty("手机")
    @TableField("phone")
    private String phone;

    @ApiModelProperty("盐值")
    @TableField("salt")
    private String salt;

    @ApiModelProperty("0：已注册；1： 已激活；2： 禁用")
    @TableField("state")
    private Integer state;

    @ApiModelProperty("密码，md5加密加盐")
    @TableField("password")
    private String password;

    @ApiModelProperty("年龄")
    @TableField("age")
    private Integer age;

    @ApiModelProperty("创建时间")
    @TableField("createtime")
    private Date createtime = new Date();

    @ApiModelProperty("头像")
    @TableField("headImg")
    private String headImg;

    @ApiModelProperty("登录id")
    @TableField("logininfo_id")
    private Long logininfo_id;

    @ApiModelProperty("用户类型")
    @TableField("user_type")
    private Integer userType;

    @ApiModelProperty("是否捐赠（0：未捐赠；1：已捐赠）")
    @TableField("is_donate")
    private Integer isDonate;

    @ApiModelProperty("账号状态0 停用 1 启用")
    private Integer disable;

    @ApiModelProperty("权限分类：0：普通用户；1：管理员；2：审核员；3：编辑员")
    private Integer type;
}
